﻿using System.Collections.Generic;
using System.Threading.Tasks;
using VisionCloud.Core.Model.Sys;
using VisionCloud.Domain.Common;
using VisionCloud.Domain.DtoModel.Sys;

namespace VisionCloud.Domain.Repository.Interface.Sys
{
    public interface ISysUserRepository : IBaseRepository<SysUser>
    {
        Task<ApiPageResult> GetPage2(SysUserCondition condition);

        /// <summary>
        /// 登录使用
        /// </summary>
        /// <param name="userDto"></param>
        /// <returns></returns>
        Task<SysUserDto> FindUser(SysUserDto userDto);

        Task<SysUserDto> FindUserByNamePwd(SysUserDto userDto);

        /// <summary>
        /// 查询某个用户（只支持用户代码Code,UserId）
        /// </summary>
        /// <param name="userDto"></param>
        /// <returns></returns>
        Task<SysUserListDto> GetUser(SysUserDto userDto);

        /// <summary>
        /// 检查是否重复数据
        /// </summary>
        /// <param name="sysUserDto"></param>
        /// <returns></returns>
        Task<ApiResult> GetCheckUser(SysUser sysUserDto);

        /// <summary>
        /// 获取注册的用户设备数量
        /// </summary>
        /// <returns></returns>
        Task<int> GetRegistedUserCount();

        Task<DogUserDto> GetDogUser(RegisterDto registerDto);

        Task<List<SysUserListDto>> GetCompanyUseListAsync(SysUserCondition condition);
    }
}